935fdbd5c47dee4383b959389ecdf28ceccd0a21,test-common/src/main/java/eu/europeana/cloud/test/CassandraTestInstance.java,CassandraTestInstance,buildClusterWithConsistencyLevel,#ConsistencyLevel#,43
Before Change
QueryOptions options = new QueryOptions().setConsistencyLevel(level);
return Cluster.builder().addContactPoints("localhost").withPort(CassandraTestInstance.PORT)
.withProtocolVersion(ProtocolVersion.V3)
.withQueryOptions(options)
.withTimestampGenerator(new AtomicMonotonicTimestampGenerator()).build();
}
/**
After Change
private Cluster buildClusterWithConsistencyLevel(ConsistencyLevel level) {
QueryOptions queryOptions = new QueryOptions().setConsistencyLevel(level);
SocketOptions socketOptions = new SocketOptions().setConnectTimeoutMillis(CONNECT_TIMEOUT_MILLIS);
return Cluster.builder().addContactPoints("localhost").withPort(CassandraTestInstance.PORT)
.withProtocolVersion(ProtocolVersion.V3)
.withQueryOptions(queryOptions)
.withSocketOptions(socketOptions)
.withRetryPolicy(new TestRetryPolicy(3,3,3))
.withTimestampGenerator(new AtomicMonotonicTimestampGenerator()).build();
}